<?php
namespace Home\Controller;
use Think\Controller;
class TestController extends Controller {
    
    public function __construct() {
        parent::__construct();
    }
    
    public function test(){
    $data = file_get_contents("php://input");
    if(is_json($data)){
        $list = json_decode($data,true);
        $this->ajaxreturn(['errCode'=>0,'msg'=>'success','data'=>$list]);
    }else{
        $this->ajaxreturn(['errCode'=>40006,'msg'=>'数据格式错误','data'=>$data]);
    }
    
   }
}